<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <title>erp</title>
    <meta name="description" content="">
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
    <meta name="robots" content="all,follow">
    <!-- Bootstrap CSS-->
    <link rel="stylesheet" href="vendor/bootstrap/css/bootstrap.min.css">
    <!-- Font Awesome CSS-->
    <link rel="stylesheet" href="vendor/font-awesome/css/font-awesome.min.css">
    <!-- Fontastic Custom icon font-->
    <link rel="stylesheet" href="css/fontastic.css">
    <!-- Google fonts - Poppins -->
    <link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Poppins:300,400,700">
    <!-- theme stylesheet-->
    <link rel="stylesheet" href="css/style.default.css" id="theme-stylesheet">
    <!-- Custom stylesheet - for your changes-->
    <link rel="stylesheet" href="css/custom.css">
    <!-- Favicon-->
    <link rel="shortcut icon" href="img/favicon.ico">
    <!--日期选择器-->
    <script src="vendor/jquery/jquery.js"></script>
    <script type="text/javascript" src="easyUI/jquery.easyui.min.js"></script>
    <link rel="stylesheet" href="easyUI/themes/default/easyui.css">
    <link rel="stylesheet" href="easyUI/themes/icon.css">
    <link rel="stylesheet" href="easyUI/demo/demo.css">
    <script src="easyUI/locale/easyui-lang-zh_CN.js"></script>

    <!-- Tweaks for older IEs--><!--[if lt IE 9]>
    <script src="https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js"></script>
    <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script><![endif]-->

    <script>
        //console.log("javascript")
        $(function () {
            //为submitBtn添加监听事件
            var selectGoods;
            var selectGoodsName;
            //此变量记录商品list
            var goods;
            //此字段记录商品详情信息
            var goodsInfo = new Array();
            var currentCustomer;
            $("#placeOrderClick").click(function () {
                console.log(goodsInfo)
                //构造json
                if (goodsInfo.length > 0) {
                    var time = $("#orderFinishTimeDateBox").val();
                    var goodsInfostr = JSON.stringify(goodsInfo);
                    var orderInfo = {"customerId":currentCustomer.id,
                        "customerName":currentCustomer.customerName,
                        "client":currentCustomer.client,
                        "buyerAddress":currentCustomer.buyerAddress,
                        "buyerPhoneNumber":currentCustomer.buyerPhoneNumber,
                        "orderFinishTime":time,"goodInfo":goodsInfostr};
                    console.log(currentCustomer)

                    $.ajax({
                        url: "/erp/order/add",
                        //构造向后端传入的json数据
                        data: orderInfo,
                        dataType:"json",
                        type:"POST",
                        //请求成功回调此函数，data为返回的数据
                        success:function (data) {
                            //判断data里的值，反馈给前端
                            if(data.code == 200) {
                                alert("新建订单成功")
                                window.location.reload()
                            } else {
                                alert(data.data)
                            }
                        }
                    })
                } else {
                    alert("请添加产品信息");
                }

            })

            $("#submitBtn").click(function () {
                for (var i in goods) {
                    if (goods[i].goodName == selectGoodsName) {
                        selectGoods = goods[i];
                        break;
                    }
                }
                console.log(selectGoods);//test ok
                //构造出商品详情列表
                var info =
                {
                    "goods":selectGoods,
                    "goodsNumber":$("#goodNumberText").val(),
                    "goodsUnit":$("#goodUnitText").val()
                }
                goodsInfo.push(info);
                generateGoodsTable(goodsInfo);
                //console.log(goodsInfo)
                //清除模态框数据
                $("#goodName").val("")
                $("#goodNumberText").val("")
                $("#goodUnitText").val("")
                //关闭模态框
                $("#goodsAddModalClose").click();
            })

            function generateGoodsTable(goodsData){
                $("#goodsInfoTable").empty();
                //添加表头信息
                $("#goodsInfoTable").append("<thead>" +
                    " <tr>\n" +
                    " <th valign=middle align=center>编号</th>" +
                    " <th valign=middle align=center>产品</th>" +
                    " <th valign=middle align=center>数量</th>" +
                    " <th valign=middle align=center>单位</th>" +
                    " </tr>"+
                    " </thead>");
                for (var i=0;i<goodsData.length;i++){
                    $("#goodsInfoTable").append("<tr>" +
                        "<td>" +
                        (i+1) +
                        "</td>" +
                        "<td>" +
                        goodsData[i].goods.goodName+
                        "</td>" +
                        "<td>" +
                        goodsData[i].goodsNumber+
                        "</td>" +
                        "<td>" +
                        goodsData[i].goodsUnit+
                        "</td>" +
                        "</tr>")
                    //添加表数据
                    /*goodsData[i].goods.goodName
                    goodsData[i].goodsNumber
                    goodsData[i].goodsUnit*/
                }
            }

            //为saveBtn添加监听事件
            $("#saveBtn").click(function () {
                console.log("saveBtn click")
                //获取要向后端传入的值
                var name = $("#customerName").val();
                var client = $("#newClientText").val();
                var address = $("#newAddressText").val();
                var phone = $("#newphoneNumberText").val();
                //发送请求
                $.ajax({
                    url: "/erp/customer/add",
                    //构造向后端传入的json数据
                    data: {"customerName":name,"client":client,"buyerAddress":address,"buyerPhoneNumber":phone},
                    // data: {},
                    // data: {},
                    dataType:"json",
                    type:"POST",
                    //请求成功回调此函数，data为返回的数据
                    success:function (data) {
                        //判断data里的值，反馈给前端
                        if(data.code == 200) {
                            alert("新建客户成功")
                        } else {
                            alert("新建客户失败")
                        }

                        //重置各个组件的初始值
                        $("#customerName").val("");
                        $("#newClientText").val("");
                        $("#newAddressText").val("");
                        $("#newphoneNumberText").val("");
                        //console.log(data)
                        $("#customerCloseBtn").click()

                    }
                })
                console.log(name,client,address,phone);
            })


            //客户公司下拉框按钮
            var customers;
            var i;
            $("#customerNameBtn").click(function () {
                console.log("customerNameBtn click")
                $.ajax({
                    url: "/erp/customer/list",
                    //构造向后端传入的json数
                    dataType:"json",
                    type:"GET",
                    //请求成功回调此函数，data为返回的数据
                    success:function (data) {
                        console.log(
                            data
                        )
                        //判断data里的值，反馈给前端
                        if (data.code==200 && data.data){
                            customers=data.data;
                            $("#customerNameList").children('li').remove();
                            for(var i = 0;i<data.data.length;i++){
                                //customers=data.data[i];
                                //customerName = data.data[i].customerName;
                                $("#customerNameList").append("<li><a href='#'>"+data.data[i].customerName+"</a></li>")
                            }

                        }

                    }
                })
            })
            //客户下拉框列表
            var client;
            var buyerAddress;
            var buyerPhoneNumber;
            $("#customerNameList").on("click","li",function(){      //只需要找到你点击的是哪个ul里面的就行
                $("#customerNameText").val($(this).text())

                for (var i = 0;i<customers.length;i++){
                    if(customers[i].customerName==$(this).text()){
                        client = customers[i].client;
                        buyerAddress = customers[i].buyerAddress;
                        buyerPhoneNumber = customers[i].buyerPhoneNumber;

                        currentCustomer = customers[i];
                    }
                }
                $("#clientNameText").val(client)
                $("#addressText").val(buyerAddress)
                $("#phoneNumberText").val(buyerPhoneNumber)


            });

            //添加产品下拉框按钮
            $("#goodNameBtn").click(function () {
                console.log("goodNameBtn click")
                $.ajax({
                    url: "/erp/goods/list",
                    //构造向后端传入的json数
                    dataType:"json",
                    type:"GET",
                    //请求成功回调此函数，data为返回的数据
                    success:function (data) {
                        console.log(
                            data
                        )
                        //判断data里的值，反馈给前端
                        if (data.code==200 && data.data){
                            goods = data.data;
                            $("#goodNameList").children('li').remove();
                            for(var i = 0;i<data.data.length;i++){
                                $("#goodNameList").append("<li><a href='#'>"+data.data[i].goodName+"</a></li>")
                            }
                        }

                    }
                })
            })
            //产品下拉框列表。
            $("#goodNameList").on("click","li",function(){
                //只需要找到你点击的是哪个ul里面的就行
                $("#goodName").val($(this).text());
                selectGoodsName = $(this).text();


            });

            //产品数量单位下拉框按钮
            $("#goodUnitBtn").click(function () {
                console.log("goodUnitBtn click")
                $.ajax({
                    url: "index.html",
                    //构造向后端传入的json数
                    dataType:"json",
                    type:"GET",
                    //请求成功回调此函数，data为返回的数据
                    success:function (data) {
                        console.log(
                            data
                        )
                        //判断data里的值，反馈给前端
                        if (data.code==200 && data.data){
                            $("#goodUnitList").children('li').remove();
                            for(var i = 0;i<data.data.length;i++){
                                $("#goodUnitList").append("<li><a href='#'>"+data.data[i].goodUnit+"</a></li>")
                            }

                        }

                    }
                })
            })

            //数量单位下拉框列表
            $("#goodUnitList").on("click","li",function(){
                //只需要找到你点击的是哪个ul里面的就行
                $("#goodUnitText").val($(this).text())

            });





        })

    </script>



    <!--<link rel="stylesheet" href="vendor/bootstrap/css/bootstrap.css">-->
    <!--<link rel="stylesheet" href="vendor/bootstrap/css/bootstrap-grid.css">-->


</head>
<body>
<div class="page">
    <!-- Main Navbar-->
    <header class="header">
        <nav class="navbar">
            <div class="container-fluid">
                <div class="navbar-holder d-flex align-items-center justify-content-between">
                    <!-- Navbar Header-->
                    <div class="navbar-header">
                        <!-- Navbar Brand -->
                    <a href="index.html" class="navbar-brand d-none d-sm-inline-block">
                        <div class="brand-text d-none d-lg-inline-block"><strong>子恒针erp</strong></div>
                    </a>

                        <!-- Toggle Button-->
                        <a id="toggle-btn" href="#" class="menu-btn active"><span></span><span></span><span></span></a>

                    </div>
                    <!-- Navbar Menu -->

                </div>
            </div>
        </nav>
    </header>
    <div class="page-content d-flex align-items-stretch">
        <!-- Side Navbar -->
        <nav class="side-navbar">

            <!-- Sidebar Navidation Menus-->
            <ul class="list-unstyled">

                <li ><a href="#producedropdownDropdown" aria-expanded="false" data-toggle="collapse"> <i class="icon-interface-windows"></i><font color="black" size="3.8"> <strong>生产管理</strong></font></a>
                    <ul id="producedropdownDropdown" class="collapse list-unstyled ">
                        <li ><a href="#orderDropdown" aria-expanded="false" data-toggle="collapse"><font color=black size="3"><strong> 订单管理</strong></font></a>
                            <ul id="orderDropdown" class="collapse list-unstyled ">
                                <li ><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;<u>新增订单</u></a></li>

                                <li><a href="index.html">&nbsp;&nbsp;&nbsp;&nbsp;查询订单</a></li>
                            </ul>
                        </li>

                        <li><a href="searchGoods.html" ><font color="#626262" size="3"><strong>产品管理</strong></font></a>
                            <!--<ul id="planDropdown" class="collapse list-unstyled ">-->
                                <!--<li><a href="addGoods.html">&nbsp;&nbsp;&nbsp;&nbsp;新增产品</a></li>-->
                                <!--<li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;查询产品</a></li>-->
                            <!--</ul>-->
                        </li>

                        <li><a href="manageCustomer.html"><font color="#626262" size="3"><strong>客户管理</strong></font></a>
                            <!--<ul id="taskDropdown" class="collapse list-unstyled ">-->
                                <!--<li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;新增客户</a></li>-->
                                <!--<li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;查询客户</a></li>-->
                            <!--</ul>-->
                        </li>

                        <li><a href="#processDropdown" aria-expanded="false" data-toggle="collapse"><font color="#626262" size="3"><strong>生产工艺管理</strong></font></a>
                            <ul id="processDropdown" class="collapse list-unstyled ">
                                <li><a href="makeProductionTechnology.html">&nbsp;&nbsp;&nbsp;&nbsp;新增生产工艺</a></li>
                                <li><a href="manageProductionTechnology.html">&nbsp;&nbsp;&nbsp;&nbsp;查询生产工艺</a></li>
                            </ul>
                        </li>

                        <li><a href="manageOutsourcingEnterprise.html"><font color="#626262" size="3"><strong>外协企业管理</strong></font></a>
                            <!--<ul id="unfinishedDropdown" class="collapse list-unstyled ">-->
                                <!--<li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;新增外协企业</a></li>-->
                                <!--<li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;管理外协企业</a></li>-->
                            <!--</ul>-->
                        </li>

                       <!-- <li><a href="#dyeingDropdown" aria-expanded="false" data-toggle="collapse"><font color="#626262" size="3"><strong>印染过程管理</strong></font></a>
                            <ul id="dyeingDropdown" class="collapse list-unstyled ">
                                <li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;印染入库</a></li>
                                <li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;印染出库</a></li>
                            </ul>
                        </li>

                        <li><a href="#finishedDropdown" aria-expanded="false" data-toggle="collapse"><font color="#626262" size="3"><strong>成品出入库管理</strong></font></a>
                            <ul id="finishedDropdown" class="collapse list-unstyled ">
                                <li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;成品入库</a></li>
                                <li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;成品出库</a></li>
                            </ul>
                        </li>

                        <li><a href="#inquireDropdown" aria-expanded="false" data-toggle="collapse"><font color="#626262" size="3"><strong>综合查询</strong></font></a>
                            <ul id="inquireDropdown" class="collapse list-unstyled ">
                                <li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;订单完成情况</a></li>
                                <li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;生产过程</a></li>
                            </ul>
                        </li>-->
                    </ul>
                </li>

                <!--库存管理-->
                <li ><a href="#stockdropdownDropdown" aria-expanded="false" data-toggle="collapse"> <i class="icon-interface-windows"></i><font  size="3.8"> <strong>库存管理</strong></font></a>
                    <ul id="stockdropdownDropdown" class="collapse list-unstyled ">
                        <li><a href="manageSupplier.html" ><font color="#626262" size="3"><strong>供应商关系管理</strong></font></a>
                            <!--<ul id="supplierDropdown" class="collapse list-unstyled">-->
                                <!--<li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;新增供应商</a></li>-->
                                <!--<li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;查询供应商</a></li>-->
                            <!--</ul>-->
                        </li>

                        <li><a href="manageRawMaterial.html" ><font color="#626262" size="3"><strong>原材料信息管理</strong></font></a>
                            <!--<ul id="rawDropdown" class="collapse list-unstyled">-->
                            <!--<li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;新增原材料</a></li>-->
                            <!--<li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;查询原材料</a></li>-->
                            <!--</ul>-->
                        </li>

                        <!--<li><a href="#purchaseDropdown" aria-expanded="false" data-toggle="collapse"><font color="#626262" size="3"><strong>原材料采购管理</strong></font></a>
                            <ul id="purchaseDropdown" class="collapse list-unstyled">
                                <li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;新增订单</a></li>
                                <li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;修改订单</a></li>
                                <li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;查询订单</a></li>
                            </ul>
                        </li-->

                        <li><a href="manageRMInventory.html" ><font color="#626262" size="3"><strong>原材料库存管理</strong></font></a>
                        </li>

                        <li><a href="managePDenterprise.html" ><font color="#626262" size="3"><strong>印染企业管理</strong></font></a>
                        </li>

                        <li><a href="manageOutsourcingRMInventory.html" ><font color="#626262" size="3"><strong>外协企业原材料管理</strong></font></a>
                        </li>

                        <li><a href="manageFinishedGoods.html" ><font color="#626262" size="3"><strong>成品库存管理</strong></font></a>
                        </li>

                       <!-- <li><a href="#customerDropdown" aria-expanded="false" data-toggle="collapse"><font color="#626262" size="3"><strong>客户关系管理</strong></font></a>
                            <ul id="customerDropdown" class="collapse list-unstyled">
                                <li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;新增客户</a></li>
                                <li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;修改客户</a></li>
                                <li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;查询客户</a></li>
                            </ul>
                        </li>

                        <li><a href="#foundryDropdown" aria-expanded="false" data-toggle="collapse"><font color="#626262" size="3"><strong>代工企业关系管理</strong></font></a>
                            <ul id="foundryDropdown" class="collapse list-unstyled">
                                <li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;新增代工企业</a></li>
                                <li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;修改代工企业</a></li>
                                <li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;查询代工企业</a></li>
                            </ul>
                        </li>

                        <li><a href="#techniqueDropdown" aria-expanded="false" data-toggle="collapse"><font color="#626262" size="3"><strong>生产工艺管理</strong></font></a>
                            <ul id="techniqueDropdown" class="collapse list-unstyled">
                                <li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;新增工艺</a></li>
                                <li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;修改工艺</a></li>
                                <li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;查询工艺</a></li>
                            </ul>
                        </li>
                        <li><a href="#dyeingcompanyDropdown" aria-expanded="false" data-toggle="collapse"><font color="#626262" size="3"><strong>印染企业关系管理</strong></font></a>
                            <ul id="dyeingcompanyDropdown" class="collapse list-unstyled">
                                <li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;新增企业</a></li>
                                <li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;修改企业</a></li>
                                <li><a href="#">&nbsp;&nbsp;&nbsp;&nbsp;查询企业</a></li>
                            </ul>
                        </li>-->
                    </ul>
                </li>

            </ul>
        </nav>

        <div class="content-inner">
            <!-- Page Header-->
            <header class="page-header">
                <div class="container-fluid">
                    <h1 class="no-margin-bottom">新增订单</h1>
                </div>
            </header>
            <!-- Breadcrumb-->
            <section>
                <div><!--订单表-->
                    <!--订单表格-->
                    <div class="col-lg-12">
                        <div class="card">

                            <div class="card-header d-flex align-items-center">
                                <h3 class="h4">订单内容</h3>
                            </div>

                            <div class="card-body">
                                <form class="form-order">
                                    <!--客户公司-->
                                    <div class="form-group row">
                                        <label class="col-lg-2 form-control-label no-padding-bottom container-fluid text-center"><font size="3.5"> 客户公司：</font></label>

                                        <div class="col-lg-8 ">
                                            <div class="input-group">
                                                <input type="text" class="form-control" id="customerNameText">
                                                <div class="input-group-btn">
                                                    <button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown" id="customerNameBtn">

                                                        <!--<span class="caret">uuu</span>-->
                                                    </button>
                                                    <ul class="dropdown-menu pull-right " id="customerNameList">

                                                    </ul>
                                                </div><!-- /btn-group -->
                                            </div><!-- /input-group -->
                                        </div><!-- /.col-lg-10 -->

                                        <button type="button" data-toggle="modal" data-target="#clientModal" class="btn btn-primary col-lg-2 "  >新增客户</button>
                                        <!--模态框-->
                                        <div id="clientModal" tabindex="-1" role="dialog" aria-labelledby="exampleModalLabel" aria-hidden="true" class="modal fade text-left">
                                            <div role="document" class="modal-dialog">
                                                <div class="modal-content">
                                                    <div class="modal-header">
                                                        <h4 id="exampleModalLabel" class="modal-title">新增客户</h4>
                                                        <button type="button" data-dismiss="modal" aria-label="Close" class="close"><span aria-hidden="true">×</span></button>
                                                    </div>
                                                    <div class="modal-body">

                                                        <form>
                                                            <div class="form-group">
                                                                <label>公司</label>
                                                                <input type="name" placeholder="Name" class="form-control" id="customerName">
                                                            </div>
                                                            <div>
                                                                <label>默认承办人</label>
                                                                <input type="text" class="form-control" id="newClientText">
                                                            </div>
                                                            <div>
                                                                <label>默认联系方式</label>
                                                                <input type="text" class="form-control" id="newphoneNumberText">
                                                            </div>
                                                            <div>
                                                                <label>默认收货地址</label>
                                                                <input type="text" class="form-control" id="newAddressText">
                                                            </div>
                                                        </form>
                                                    </div>
                                                    <div class="modal-footer">
                                                        <button type="button" data-dismiss="modal" class="btn btn-secondary" id="customerCloseBtn">关闭</button>
                                                        <button type="button" class="btn btn-primary" id="saveBtn">保存</button>
                                                    </div>
                                                </div>
                                            </div>
                                        </div><!--模态框-->

                                    </div><!--客户公司-->

                                    <!--委托人-->
                                    <div>
                                        <div class="form-group row">
                                            <label class="col-lg-2 form-control-label no-padding-bottom container-fluid text-center"><font size="3.5">委托人：</font></label>
                                            <div class="col-lg-10 ">
                                                <div class="input-group">
                                                    <input type="text" class="form-control" id="clientNameText">

                                                </div><!-- /input-group -->
                                            </div>

                                        </div>

                                    </div><!--委托人-->

                                    <!--联系方式-->
                                    <div>
                                        <div class="form-group row">
                                            <label class="col-lg-2 form-control-label no-padding-bottom container-fluid text-center"><font size="3.5">联系方式：</font></label>
                                            <div class="col-lg-10">
                                                <div class="input-group">
                                                    <input type="text" class="form-control" id="phoneNumberText">
                                                </div>
                                            </div>

                                        </div>
                                    </div><!--联系方式-->


                                    <!--送货地址-->
                                    <div>
                                        <div class="form-group row">
                                            <label class="col-lg-2 form-control-label no-padding-bottom container-fluid text-center"><font size="3.5">送货地址：</font></label>
                                            <div class="col-lg-10 ">
                                                <div class="input-group">
                                                    <input type="text" class="form-control" id="addressText">

                                                </div><!-- /input-group -->
                                            </div>
                                        </div>

                                    </div><!--送货地址-->



                                    <!--交货时间-->
                                    <div>
                                        <div class="form-group row">
                                            <label class="col-lg-2 form-control-label no-padding-bottom container-fluid text-center"><font size="3.5">交货时间：</font></label>
                                            <div class="col-lg-10 ">
                                                <div class="input-group">

                                                    <input id="orderFinishTimeDateBox" class="easyui-datebox" label="" labelPosition="top" style="width:100%;">

                                                </div><!-- /input-group -->
                                            </div>

                                        </div>
                                    </div><!--交货时间-->

                                    <!--订单详情-->
                                    <div>
                                        <div class="form-group row">
                                            <label class="col-lg-2 form-control-label no-padding-bottom container-fluid text-center"><font size="3.5">订单详情：</font></label>
                                            <!--<div class="col-lg-8 ">-->
                                            <!--<div class="input-group">-->
                                            <!--<input type="text" class="form-control" >-->
                                            <!--<textarea class="form-control" rows="3"></textarea>-->

                                            <!--</div>--><!-- /input-group -->
                                            <!--</div>-->

                                            <button type="button" data-toggle="modal" data-target="#goodModal" class="btn btn-primary col-lg-10 ">添加产品 </button>
                                            <!--添加产品模态框-->
                                            <div id="goodModal" tabindex="-1" role="dialog" aria-labelledby="exampleModalLabel" aria-hidden="true" class="modal fade text-left">
                                                <div role="document" class="modal-dialog">
                                                    <div class="modal-content">
                                                        <div class="modal-header">
                                                            <h4 id="goodModalLabel" class="modal-title">添加产品</h4>
                                                            <button type="button" data-dismiss="modal" aria-label="Close" class="close"><span aria-hidden="true">×</span></button>
                                                        </div>
                                                        <div class="modal-body">

                                                            <form>
                                                                <div class="form-group">
                                                                    <label>产品</label>
                                                                    <div  >
                                                                        <div class="input-group">
                                                                            <input type="text" class="form-control" id="goodName">
                                                                            <div class="input-group-btn">
                                                                                <button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown" id="goodNameBtn">

                                                                                    <!--<span class="caret">uuu</span>-->
                                                                                </button>
                                                                                <ul class="dropdown-menu pull-right " id="goodNameList"></ul>

                                                                            </div><!-- /btn-group -->
                                                                        </div><!-- /input-group -->
                                                                    </div>
                                                                </div>
                                                                <div class="form-group">
                                                                    <label>数量</label>
                                                                    <div  >
                                                                        <div class="input-group">
                                                                            <input type="number" class="form-control" id="goodNumberText" >

                                                                            <input type="text" class="form-control" id="goodUnitText" placeholder="单位">
                                                                            <div class="input-group-btn">
                                                                                <button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown" id="goodUnitBtn"></button>
                                                                                <ul class="dropdown-menu pull-right" id="goodUnitList">
                                                                                    <li><a href="#">匹</a></li>
                                                                                    <li><a href="#">千克</a></li>

                                                                                </ul>

                                                                            </div>

                                                                            <!--<div class="input-group-btn">
                                                                                <button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown" id="goodUnitBtn">

                                                                                    <span class="caret" id="goodUnit">单位</span>
                                                                                </button>
                                                                                <ul class="dropdown-menu pull-right " id="goodUnitList">
                                                                                    <li><a href="#">匹</a></li>
                                                                                    <li><a href="#">公斤</a></li>


                                                                                </ul>
                                                                            </div>--><!-- /btn-group --><!--下拉框按钮-->

                                                                        </div><!-- /input-group -->
                                                                    </div>
                                                                </div>

                                                            </form>
                                                        </div>
                                                        <div class="modal-footer">
                                                            <button type="button" data-dismiss="modal" class="btn btn-secondary" id="goodsAddModalClose">关闭</button>
                                                            <button type="button" class="btn btn-primary" id="submitBtn">添加</button>
                                                        </div>
                                                    </div>
                                                </div>
                                            </div><!--添加产品 模态框-->
                                        </div>
                                    </div><!--订单详情-->

                                    <div>
                                        <table class="table table-striped table-sm " id="goodsInfoTable">
                                        </table>
                                    </div><!--添加商品预览表格-->

                                    <div>
                                        <div class="col-lg-1 form-group container-fluid float-right">
                                            <input type="submit" value="提交" class="btn btn-primary" id="placeOrderClick">
                                        </div>
                                    </div>


                                </form>
                            </div>
                        </div>
                    </div><!--订单表格-->
                </div><!--订单表-->
            </section>

            <!-- Page Footer-->
            <footer class="main-footer">
                <div class="container-fluid">
                    <div class="row">
                        <div class="col-sm-6">
                            <p>Your company &copy; 2017-2019</p>
                        </div>

                    </div>
                </div>
            </footer>
        </div>
    </div>
</div>
<!-- JavaScript files-->
<script src="vendor/jquery/jquery.min.js"></script>
<script src="vendor/popper.js/umd/popper.min.js"> </script>
<script src="vendor/bootstrap/js/bootstrap.min.js"></script>
<script src="vendor/jquery.cookie/jquery.cookie.js"> </script>
<script src="vendor/chart.js/Chart.min.js"></script>
<script src="vendor/jquery-validation/jquery.validate.min.js"></script>
<!-- Main File-->
<script src="js/front.js"></script>
</body>
</html>
